alpha matching: ensure that extracted header values are not reused between streams#16721
alpha matching: ensure that extracted header values are not reused between streams#16721
Conversation
This was incorrectly causing the same values to be reused when the same match input was used between two streams and the header was present in both streams. Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
|
I think perhaps later on it would make sense to have the API return a implementable interface so that we can use that to wrap various string storage objects to avoid unnecessary copies, but this should fix the immediate issue. |
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
| data.onRequestHeaders(request_headers); | ||
|
|
||
| EXPECT_EQ(input.get(data).data_, "bar"); | ||
| EXPECT_EQ(input.get(data).data_, "bar"); |
There was a problem hiding this comment.
Here and below -- why a duplicate check is required? Perhaps add a comment here?
There was a problem hiding this comment.
Old code I think, let me remove one of them
|
Could you also add a test for |
|
LMK when CI issues are resolved. /wait |
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
|
/retest |
|
Retrying Azure Pipelines: |
mattklein123
left a comment
There was a problem hiding this comment.
Thanks looks good. Can you merge main?
/wait
Signed-off-by: Snow Pettersen <snowp@lyft.com>
Signed-off-by: Snow Pettersen <snowp@lyft.com>
…tween streams (envoyproxy#16721) This was incorrectly causing the same values to be reused when the same match input was used between two streams and the header was present in both streams. Signed-off-by: Snow Pettersen <snowp@lyft.com>
Fixes an issue where the extracted header value would be persisted between streams, resulting in incorrect
matching results. Streams that should not match would match due to the previous stream having a header
set that matches the result.
Risk Level: Medium, change to alpha feature
Testing: UT test case
Docs Changes: n/a
Release Notes: n/a
Platform Specific Features: n/a